<?php if( ($iNodeId)  ): ?>
  <script type="text/javascript">
    $(document).ready(function(){
       //hiden
       if (!($("#main_menu_edit").hasClass("show_active")))
       {
         $(".node_edit").hide();
       }
       if (!($("#main_menu_add").hasClass("show_active")))
       {
         $(".node_add").hide();
       }

       //to function add
       $("#<?php echo 'add_'.$iNodeId; ?>").click(function() {
        $("#<?php echo 'add_'.$iNodeId; ?>").hide();
        $("#ca_pnsm_message_panel").load("<?php echo url_for('ca_add_node',array('parent_node_id' => $iNodeId )); ?>");
       });

       //to function edit
       $("#<?php echo 'edit_'.$iNodeId; ?>").click(function() {
        $("#<?php echo 'edit_'.$iNodeId; ?>").hide();
        $("#ca_pnsm_message_panel").load("<?php echo url_for('ca_rename_node',array('node_id' => $iNodeId )); ?>");
       });

    });
  </script>

  <?php echo  image_tag('/caPropelTreePlugin/css/images/page_edit.png',array('id' => 'edit_'.$iNodeId, 'class' => 'node_edit action', 'alt' => 'edit', 'absolute' => true)); ?>
  <?php echo  image_tag('/caPropelTreePlugin/css/images/page_add.png',array('id' => 'add_'.$iNodeId, 'class' => 'node_add action', 'alt' => 'add', 'absolute' => true)); ?>
<?php endif; ?>
  